/*******************************************************************************
 * Copyright(c) 2023 Levetop Semiconductor Co.,Led. All rights reserved.
 * @file     needle.h
 * @author   UartTFT Application Team
 * @version  V0.0.1
 * @date     2023-01-11
 * @brief    This file provides UartTFT Application display function
 ********************************************************************************/

#ifndef NEEDLE_H_
#define NEEDLE_H_

#include "type.h"
#include "module_select.h"

/**********pointer************/

extern uint8_t Pointer_Count_num;
extern uint8_t Pointer_Count_flag;

typedef struct
{
	uint16_t v_add;
	uint16_t base_id;
	uint16_t x;
	uint16_t y;
	uint16_t w;
	uint16_t h;
	uint16_t Pointer_x;
	uint16_t Pointer_y;
	uint16_t Sangle;
	uint16_t Eangle;
	uint16_t once_angle;
	int16_t current_angle;
	uint8_t	effect;
	uint16_t center_id;
	uint8_t	Show_Number;
	uint16_t Num_add;
	uint8_t	Num_type;
	uint16_t Num_x;
	uint16_t Num_y;
	uint16_t Num_sid;
	uint16_t Num_eid;
	uint8_t	Num_Alig;
	uint8_t leading_zero;
	uint8_t	Num_Nint;
	uint8_t	Num_Dint;
	uint8_t	mode;
	uint16_t Pointer_w;
	uint16_t Pointer_h;
	uint16_t L1;
	uint16_t L2;
	uint32_t L1_colour;
	uint32_t L2_colour;
	uint16_t Pointer_sid;
	uint16_t Pointer_eid;
	uint16_t Pointer_id;

	//Added By Jason
	uint8_t flag;
	int16_t pre_angle;
	uint16_t pre_num_x;
	uint16_t pre_num_y;
	uint16_t pre_num_w;
	uint16_t pre_num_h;
	uint16_t pre_pointer_x;
	uint16_t pre_pointer_y;
	uint16_t pre_pointer_w;
	uint16_t pre_pointer_h;
} Pointer_Info;

//extern Pointer_Info gPointer_Info[];
extern Pointer_Info gPointer_Info[4];
extern uint8_t Pointer_Count_num;
extern uint8_t Pointer_Count_flag;
extern void Check_Pointer(void);
extern void Pointer_display(uint8_t type, uint8_t *buff);
extern uint8_t Run_Pointer(uint8_t num);

#endif /* NEEDLE_H_ */
